package com.cheng.web.action.transit;

import org.apache.struts2.convention.annotation.Action;
import org.apache.struts2.convention.annotation.Namespace;
import org.apache.struts2.convention.annotation.ParentPackage;
import org.apache.struts2.convention.annotation.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;

import com.cheng.bos.actionUtils.ActionUtils;
import com.cheng.domain.transit.DeliveryInfo;
import com.cheng.domain.transit.TransitInfo;
import com.cheng.service.transit.DeliveryinfoService;

@ParentPackage("json-default")
@Namespace("/deliveryinfo")
@Controller
@Scope("prototype")
public class DeliveryinfoAction extends ActionUtils<DeliveryInfo> {

	@Autowired
	private DeliveryinfoService deliveryinfoService;
	
	private Integer transitinfoid;
	public void setTransitinfoid(Integer transitinfoid) {
		this.transitinfoid = transitinfoid;
	}


	@Action(value="deliveryinfo_creat",results={@Result(name="success",type="redirect",location="../pages/transit/transitinfo.html")})
	public String creatInOutStoreInfo(){
		deliveryinfoService.save(model,transitinfoid);
		return SUCCESS;
	}
	
	
}
